﻿using AbpOne.Domain.Blog;
using AbpOne.Domain.HotNews;
using AbpOne.Domain.Wallpaper;
using Microsoft.EntityFrameworkCore;
using Volo.Abp.Data;
using Volo.Abp.EntityFrameworkCore;

namespace AbpOne.EntityFrameworkCore {
    [ConnectionStringName("Sqlite")]
    public class AbpOneDbContext : AbpDbContext<AbpOneDbContext> {
        public DbSet<Post> Posts { get; set; }
        public DbSet<Category> Categories { get; set; }
        public DbSet<Tag> Tags { get; set; }
        public DbSet<PostTag> PostTags { get; set; }
        public DbSet<FriendLink> FriendLinks { get; set; }

        public DbSet<Wallpaper> Wallpapers { get; set; }

        public DbSet<HotNews> HotNewses { get; set; }

        public AbpOneDbContext(DbContextOptions<AbpOneDbContext> options) : base(options) {
        }

        protected override void OnModelCreating(ModelBuilder modelBuilder) {
            base.OnModelCreating(modelBuilder);

            modelBuilder.Configure();
        }
    }
}